package com.schoolcloud.serve.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.schoolcloud.common.model.PageDTO;
import com.schoolcloud.serve.entity.ItemRequests;
import com.schoolcloud.serve.query.ItemRequestQuery;
import com.schoolcloud.serve.service.ItemRequestsService;
import com.schoolcloud.serve.mapper.ItemRequestsMapper;
import com.schoolcolud.daomybatisplus.dto.MpPageUtil;
import org.springframework.stereotype.Service;

/**
* @author hongmizfb
* @description 针对表【item_requests(通用请求表（认领或者归还))】的数据库操作Service实现
* @createDate 2025-04-25 22:47:27
*/
@Service
public class ItemRequestsServiceImpl extends ServiceImpl<ItemRequestsMapper, ItemRequests>
    implements ItemRequestsService{

    @Override
    public PageDTO<ItemRequests> getRequestPage(ItemRequestQuery query) {
        Page<ItemRequests> page = lambdaQuery().page(query.toMpPage());
        return MpPageUtil.of(page, ItemRequests.class);
    }
}




